import { hilog } from '@kit.PerformanceAnalysisKit';

export interface ILogger{
  log(level:hilog.LogLevel,tag:string,...args: string[]):void
}

export namespace Logger {

  const TAG = 'DrawerScaffold'

  export let logger:ILogger|undefined = undefined

  export function debug(...args: string[]): void {
    logger?.log(hilog.LogLevel.DEBUG,TAG,...args)
  }

  export function info(...args: string[]): void {
    logger?.log(hilog.LogLevel.INFO,TAG,...args)
  }

  export function warn(...args: string[]): void {
    logger?.log(hilog.LogLevel.WARN,TAG,...args)
  }

  export function error(...args: string[]): void {
    logger?.log(hilog.LogLevel.ERROR,TAG,...args)
  }


}